package models

import "gorm.io/gorm"

// 用户和角色关系表
type UserRole struct {
	gorm.Model
	Uid int `gorm:"int"`
	Rid int `gorm:"int"`
}

// 角色表
type Role struct {
	gorm.Model
	RoleName string `gorm:"varchar(30)"`
}

// 角色和权限关系表
type RoleNode struct {
	gorm.Model
	Rid int `gorm:"int"`
	Nid int `gorm:"int"`
}

// 权限表
type Node struct {
	gorm.Model
	NodeName string `gorm:"varchar(30)"`
}

//Car

type Car struct {
	gorm.Model
	CarName    string `gorm:"varchar(50)" json:"carName"`
	CarContent string `gorm:"varchar(50)" json:"carContent"`
}
type CarType struct {
	gorm.Model
	Cid      int    `gorm:"int"`
	TypeName string `gorm:"varchar(30)"`
	Price    int    `gorm:"int"`
}
type CarList struct {
	OrderId    int    `gorm:"int"`
	CarName    string `gorm:"varchar(50)" json:"carName"`
	CarContent string `gorm:"varchar(50)" json:"carContent"`
	TypeName   string `gorm:"varchar(30)"`
	Price      int    `gorm:"int"`
}
